﻿using BCCommon.Enums;
using System.ComponentModel.DataAnnotations;

namespace BCDto.Common.DeviceInfo
{
    /// <summary>
    /// 设备信息
    /// </summary>
    public class DeviceInfoPutDto
    {
        /// <summary>
        /// 操作系统类型。
        /// </summary>
        [Display(Name = "操作系统类型")]
        [Required(ErrorMessage = "{0} 不能为空")]
        public OSType OSType { get; set; }

        /// <summary>
        /// 操作系统版本。
        /// </summary>
        [Display(Name = "操作系统版本")]
        [Required(ErrorMessage = "{0} 不能为空")]
        [StringLength(50, ErrorMessage = "{0} 最长为 {1} 个字符")]
        public string OSVersion { get; set; }

        /// <summary>
        /// 型号。
        /// </summary>
        [Display(Name = "型号")]
        [Required(ErrorMessage = "{0} 不能为空")]
        [StringLength(50, ErrorMessage = "{0} 最长为 {1} 个字符")]
        public string Model { get; set; }

        /// <summary>
        /// 设备序列号。
        /// </summary>
        [Display(Name = "设备序列号")]
        [Required(ErrorMessage = "{0} 不能为空")]
        [StringLength(50, ErrorMessage = "{0} 最长为 {1} 个字符")]
        public string DeviceId { get; set; }
        /// <summary>
        /// 推送令牌
        /// </summary>
        [Display(Name = "推送令牌")]
        [Required(ErrorMessage = "{0} 不能为空")]
        [StringLength(255, ErrorMessage = "{0} 最长为 {1} 个字符")]
        public string PushToken { get; set; }

        /// <summary>
        /// 推送类型。
        /// </summary>
        [Display(Name = "推送类型")]
        [Required(ErrorMessage = "{0} 不能为空")]
        public PushType PushType { get; set; }
        
        /// <summary>
        /// 安静模式。
        /// </summary>
        [Display(Name = "安静模式")]
        [Required(ErrorMessage = "{0} 不能为空")]
        public bool QuietMode { get; set; }
    }
}
